//使用define定义模块
define(["jquery","text!./modules/market/market.html","css!./modules/market/market.css","./lib/baiduTemplate.js"], function($,marketPage){
	return {
		init : function(){
        $("#market").html(marketPage)
		$.getJSON("data/market.json",function(data){
			
				var htmlStr = baidu.template("left1",data);
				$("#market").html(htmlStr); 
				$(".right ul").hide();
				$(".right ul").eq(0).show();
				$(".left").on("click","li",function(e){
			       var a=e.target;
			       var index=this.className;
			       console.log(index);
		          $(".right ul").hide();
			      $("."+index).show();
		        })	
			
				
		}); 
		

		}
	}
});	